package es.techideas.appsjam;

import android.app.Activity;
import android.content.Context;
import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.view.View.OnClickListener;
import android.view.Window;
import android.widget.Button;

public class MainActivity extends Activity {
	
	private Button info;
	private Button greenPoints;
	private Button play;
	
	private Context context;
	
    @Override
    public void onCreate(Bundle savedInstanceState) {
    	requestWindowFeature(Window.FEATURE_NO_TITLE);
        super.onCreate(savedInstanceState);
        setContentView(R.layout.main);
        
        context = getApplicationContext();
        
        initializeView();
    }
    
    private void initializeView() {
    	
    	info = (Button) findViewById(R.id.main_info_button);
    	greenPoints = (Button) findViewById(R.id.main_greenpoints_button);
    	play = (Button) findViewById(R.id.main_play_button);
    	
    	info.setOnClickListener(new OnClickListener() {
			public void onClick(View v) {
				Intent intent = new Intent(MainActivity.this, InfoActivity.class);
				startActivity(intent);
			}
		});
    	
    	greenPoints.setOnClickListener(new OnClickListener() {
			public void onClick(View v) {
				Intent intent = new Intent(MainActivity.this, GreenPointsMapActivity.class);
				startActivity(intent);

			}
		});
    	
    	play.setOnClickListener(new OnClickListener() {
			public void onClick(View v) {
				Intent intent = new Intent(MainActivity.this, AppsJam.class);
				startActivity(intent);
			}
		});
    	
    	
    }
}